import json

data = [{"name": "zs", "age": 18}, {"name": "hh", "age": 28}, {"name": "zss", "age": 13}]
json_s = json.dumps(data, ensure_ascii=False)
print(type(json_s), json_s)

data_dict = {"name": "dict", "age": 18}
json_d = json.dumps(data_dict)
print(json_d)

s = '[{"name": "zs", "age": 18}, {"name": "hh", "age": 28}, {"name": "zss", "age": 13}]'
l = json.loads(s)
print(type(l), l)

sd = '{"name": "dict", "age": 18}'
ld = json.loads(sd)
